IMotion.InchGroup method
Commands a never-ending controlled motion at a specified velocity for an axis group with a maximum distance. After the axis reaches the maximum distance it will automatically stop.
Namespace: IntervalZero.KINGSTAR.Base.ApiAssembly: IntervalZero.KINGSTAR.Base.Api (in IntervalZero.KINGSTAR.Base.dll) Version: 4.4.0.0
Syntax
KsCommandStatus InchGroup(
int Index,
double[] Distance,
double[] Velocity,
double Acceleration,
double Deceleration,
double Jerk,
McCoordSystem CoordSystem
)
Function InchGroup(
Index As Integer,
Distance As Double(),
Velocity As Double(),
Acceleration As Double,
Deceleration As Double,
Jerk As Double,
CoordSystem As McCoordSystem
) As KsCommandStatus
Parameters
Index [in]
Type: int
The index of an axis group. Indexes are zero based. You can have up to 32 groups.
Distance [in]
Type: double[]
The maximum distance traveled by a move.
Velocity [in]
Type: double[]
A value of the specified velocity. [unit/second]
Acceleration [in]
Type: double
A value of the acceleration. The unit is determined by McProfileType. (increasing energy of the motor) [unit/second2] or [second]
Deceleration [in]
Type: double
A value of the deceleration. The unit is determined by McProfileType. (decreasing energy of the motor) [unit/second2] or [second]
Jerk [in]
Type: double
A value of the jerk. The unit is determined by McProfileType. [unit/second3] or [second]
CoordSystem [in]
Type: McCoordSystem
A coordinate system. It supports only ACS.
Return value
Type: KsCommandStatus
Returns the KsCommandStatus class.
Remarks
- The Velocity, Acceleration, Deceleration and Jerk are for each axis in the group, not for the path values. If one of these parameters' values, for example, Acceleration, exceeds the maximum Acceleration of one of the axes in the group, the axis will use its own max Acceleration value. Other axes use the provided values.
- Velocity and Distance can be modified when the axis group is running.
- The elements of the Distance array must be greater than zero (> 0). That is, the distance for each axis to travel is greater than zero (> 0).
- InchGroup can be used only in the GroupStandstill state.
- If one of the axes in the group has done the movement and others haven't, but you want to keep that axis moving, you have two choices:
- Increase the distance. The axis will travel the increased part in another movement. For example, you change the distance from 2000 to 2500. The axis will travel 500 units more after it traveled 2000 units.
- Change the velocity of the axis. The axis will travel the current distance again using the new velocity.
IMPORTANT: If the distance is very short and the velocity is very fast, the "braking distance" for the axis may exceed the distance you specified, which can cause the axis to crash.
Examples
N/A
See also